<div class="container">
    <div class="page-header">
        <h1>{if $id}Редактирование{else}Добавление{/if} места</h1>
    </div>
    <div class="row">
    	<form action="{$cururl}" method="post" class="form-horizontal">
        	<fieldset>
        	    <div class="control-group{if $errors.title} error{/if}">
                    <label for="title" class="control-label">Название</label>
                    <div class="controls">
                        <input type="text" name="title" id="title" class="input-xlarge" value="{$aData.title}">
                        <p class="help-block{if !$errors.title} invisible{/if}">{$errors.title|default:'&nbsp;'}</p>
                    </div>
                </div>
                <div class="control-group{if $errors.site_id} error{/if}">
                    <label for="site_id" class="control-label">Сайт</label>
                    <div class="controls">
                        <select name="site_id" id="site_id" class="input-xlarge">
                            <option value="">-- Выберите --</option>
                            {foreach from=$aSites item=item}
                            <option value="{$item.id}"{if $aData.site_id == $item.id} selected{/if}>{$item.title}</option>
                            {/foreach}
                        </select>
                        <p class="help-block{if !$errors.site_id} invisible{/if}">{$errors.site_id|default:'&nbsp;'}</p>
                    </div>
                </div>
                <div class="control-group{if $errors.width} error{/if}">
                    <label for="width" class="control-label">Ширина</label>
                    <div class="controls">
                        <input type="text" name="width" id="width" class="input-xlarge" value="{$aData.width}">
                        <p class="help-block{if !$errors.width} invisible{/if}">{$errors.width|default:'&nbsp;'}</p>
                    </div>
                </div>
                <div class="control-group{if $errors.height} error{/if}">
                    <label for="height" class="control-label">Высота</label>
                    <div class="controls">
                        <input type="text" name="height" id="height" class="input-xlarge" value="{$aData.height}">
                        <p class="help-block{if !$errors.height} invisible{/if}">{$errors.height|default:'&nbsp;'}</p>
                    </div>
                </div>
                <div class="form-actions">
                    <button class="btn btn-success" type="submit">
                        <i class="icon-{if $id}edit{else}plus{/if} icon-white"></i> {if $id}Редактировать{else}Добавить{/if}</button>
                </div>
        	</fieldset>
    	</form>
    </div>
</div>